/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package tree;
import common.Dicionario;

/**
 *
 * @author cassio
 */

public class AvlNode {

	protected int height;      // Height
    protected Dicionario key;
    protected AvlNode left, right;
    
    public AvlNode ( Dicionario theElement ) {
    	this( theElement, null, null );
    }
    public AvlNode ( Dicionario theElement, AvlNode lt, AvlNode rt ) {
    	key = theElement;
    	left = lt;
    	right = rt;
    	height = 0;
    }
    public int getHeight() {
    	return height;
    }
    public void setHeight(int height) {
    	this.height = height;
    }
    public Dicionario getKey() {
        return key;
    }
    public void setKey(Dicionario key) {
    	this.key = key;
    }
    public AvlNode getLeft() {
    	return left;
    }
    public void setLeft(AvlNode left) {
    	this.left = left;
    }
    public AvlNode getRight() {
    	return right;
    }
    public void setRight(AvlNode right) {
    	this.right = right;
    }
}
